<div class="r_crumbs">
  <a href="javascript:;">首页</a>
  <a href="javascript:;">机器人管理</a>
  逻辑基点管理
</div>
<div class="r_main">
  <app-alert></app-alert>
  <div class="r_box">
    <div class="r_boxHead">
      <h2>逻辑新增</h2>
    </div>
    <div class="row">
      <div class="col-md-2"></div>
      <div class="col-md-8">
        <div class="form-group">
          <label for="inputEmail3" class="col-sm-4 control-label logic-text">基点名称</label>
          <div class="col-sm-5 logic-ctr">
            <input type="text" class="form-control" id="inputEmail3" placeholder="基点名称"
                   [(ngModel)]="curaddLogicInfo.name">
          </div>
        </div>
        <div class="form-group">
          <label for="inputPassword3" class="col-sm-4 control-label logic-text">地图</label>
          <div class="col-sm-5 logic-ctr">
            <select class="form-control" [(ngModel)]="curaddLogicInfo.mapId"
                    (change)="queryListPath($event.target.value)">
              <option value="" selected>请选择</option>
              <option *ngFor="let obj of logic" value="{{obj.mapId}}">{{obj.name}}</option>
            </select>
          </div>
        </div>
        <div class="form-group">
          <label for="inputPassword3" class="col-sm-4 control-label logic-text">路径id</label>
          <div class="col-sm-5 logic-ctr">
            <select class="form-control" [(ngModel)]="curaddLogicInfo.pathId" (change)="getP($event.target.value)"
                    (click)="selectPath()">
              <option value="" selected>请选择</option>
              <option *ngFor="let obj of path" value="{{obj.id}}">{{obj.name}}</option>
            </select>
          </div>
        </div>
        <div class="form-group">
          <label for="inputPassword9" class="col-sm-4 control-label logic-text">事件id</label>
          <div class="col-sm-5 logic-ctr">
            <select class="form-control" id='inputPassword9' (change)="selEvent($event.target.value)"
                    onmousedown="if(this.options.length>4){this.size=5}" onblur="this.size=0" onchange="this.size=0">
              <option value="" selected>请选择</option>
              <option *ngFor="let obj of addEvent" value="{{obj.id}}">{{obj.name}}</option>
            </select>
          </div>
        </div>
        <div class="form-group">
          <label for="inputPassword8" class="col-sm-4 control-label logic-text">物理基点</label>
          <div class="col-sm-5 logic-ctr">
            <select class="form-control" id='inputPassword8' [(ngModel)]="curaddLogicInfo.realNodeId" (click)="getPhysical()">
              <option value="" selected>请选择</option>
              <option *ngFor="let obj of realInfoPage" value="{{obj.nodeId}}">{{obj.name}}</option>
            </select>
          </div>
        </div>
        <div class="form-group">
          <label for="inputPassword7" class="col-sm-4 control-label logic-text">排序</label>
          <div class="col-sm-5 logic-ctr">
            <input type="text" class="form-control" id="inputPassword7" placeholder="排序"
                   [(ngModel)]="curaddLogicInfo.sort">
          </div>
        </div>
        <div class="form-group">
          <label for="inputPassword6" class="col-sm-4 control-label logic-text">文件上传</label>
          <div class="col-sm-5 logic-ctr">
            <input type="file" ng2FileSelect [uploader]="uploader" (change)="selectedFileOnChanged($event)"
                   id="inputPassword6" accept="image/png,image/jpeg,image/jpg"/>
          </div>
        </div>
        <div class="form-group">
          <label for="inputPassword3" class="col-sm-4 control-label logic-text"></label>
          <div class="col-sm-5 logic-ctr">
            <button type="button" class="btn btn-info " id='inputPassword3' (click)="onAddLo()">保存</button>
          </div>
        </div>
      </div>
      <div class="col-md-2"></div>
    </div>
    <div style="width: 200px;height: 200px;margin: 0 auto;">
      <img src="{{imgUrl}}" alt="" style="width: 200px;height: 200px;margin: 0 auto;">
    </div>
  </div>
</div>


